/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.waldura.tw;

/**
 *
 * @author ssk
 */
public class main {

    //public static final City A = City.valueOf('A');

    private static City P = City.valueOf('P');
    private static City O = City.valueOf('O');
    private static City I = City.valueOf('I');
    private static City U = City.valueOf('U');
    private static DenseRoutesMap mapa;
    private static DijkstraEngine prueba;

    public static void main(String[] args) {

       mapa = new DenseRoutesMap(21);
       mapa.addDirectRoute(P, O, 3);
       mapa.addDirectRoute(P, U, 4);
       mapa.addDirectRoute(P, I, 1);
       mapa.addDirectRoute(O, U, 2);
       mapa.addDirectRoute(I, U, 6);
        //System.out.println("el index es "+ P.getIndex());
        int hola = mapa.getDistance(P, U);
        System.out.println("asda "+ U.getIndex());
        
        
        prueba = new DijkstraEngine(mapa);
        
       // prueba.execute(P, O);
        prueba.execute(P, U);
//        prueba.execute(P, I);
//        prueba.execute(O, U);
//        prueba.execute(I, U);
        //prueba.execute(P, )
        hola = prueba.getShortestDistance(U);
        
        
        System.out.println("asd "+ hola);



    }
}
